/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */
package v2.br.ufba.lasid.virt;

import v2.br.ufba.lasid.net.INode;
import v2.br.ufba.lasid.virt.handlers.IHypervisorHandler;

/**
 *
 * @author aliriosa
 */
public class Xen implements IHypervisor{

    INode node;
    IHypervisorHandler handler;
        
    public Xen(INode node) {
        this.node = node;
    }
        
    public INode getNode() {
        return node;
    }

    public void startup(IVirtualMachine machine) throws Exception {
        handler.startup(machine);
    }

    public void shutdown(IVirtualMachine machine) throws Exception {
        handler.shutdown(machine);
    }

    public void migrate(IVirtualMachine machine, INode node) throws Exception {
        handler.migrate(machine, node);
    }

    public void update(IVirtualMachine machine) throws Exception {
        handler.update(machine);
    }    

    public void connect() throws Exception {
        handler.connect();
    }

    public void disconnect() throws Exception {
        handler.disconnect();
    }

    public boolean isConnected() throws Exception {
        return handler.isConnected();
    }
}
